package com.example.crowdfunding.entity;

import java.util.ArrayList;
import java.util.List;

public class Menu {

    private Integer id;

    private Integer pid;

    private String name;

    private String url;

    private String icon;

    private String deleted;

    private String createTime;

    private String updateTime;

    private String deleteTime;

    private List<Menu> children = new ArrayList<>();

    private Boolean open = true;

    public Menu(Integer id, Integer pid, String name, String url, String icon, String deleted, String createTime, String updateTime, String deleteTime, List<Menu> children, Boolean open) {

        this.id = id;
        this.pid = pid;
        this.name = name;
        this.url = url;
        this.icon = icon;
        this.deleted = deleted;
        this.createTime = createTime;
        this.updateTime = updateTime;
        this.deleteTime = deleteTime;
        this.children = children;
        this.open = open;
    }

    @Override
    public String toString() {

        return "Menu{" +
                "id=" + id +
                ", pid=" + pid +
                ", name='" + name + '\'' +
                ", url='" + url + '\'' +
                ", icon='" + icon + '\'' +
                ", deleted='" + deleted + '\'' +
                ", createTime='" + createTime + '\'' +
                ", updateTime='" + updateTime + '\'' +
                ", deleteTime='" + deleteTime + '\'' +
                ", children=" + children +
                ", open=" + open +
                '}';
    }

    public Menu() {

    }

    public Integer getId() {

        return id;
    }

    public void setId(Integer id) {

        this.id = id;
    }

    public Integer getPid() {

        return pid;
    }

    public void setPid(Integer pid) {

        this.pid = pid;
    }

    public String getName() {

        return name;
    }

    public void setName(String name) {

        this.name = name == null ? null : name.trim();
    }

    public String getUrl() {

        return url;
    }

    public void setUrl(String url) {

        this.url = url == null ? null : url.trim();
    }

    public String getIcon() {

        return icon;
    }

    public void setIcon(String icon) {

        this.icon = icon == null ? null : icon.trim();
    }

    public String getDeleted() {

        return deleted;
    }

    public void setDeleted(String deleted) {

        this.deleted = deleted == null ? null : deleted.trim();
    }

    public String getCreateTime() {

        return createTime;
    }

    public void setCreateTime(String createTime) {

        this.createTime = createTime == null ? null : createTime.trim();
    }

    public String getUpdateTime() {

        return updateTime;
    }

    public void setUpdateTime(String updateTime) {

        this.updateTime = updateTime == null ? null : updateTime.trim();
    }

    public String getDeleteTime() {

        return deleteTime;
    }

    public void setDeleteTime(String deleteTime) {

        this.deleteTime = deleteTime == null ? null : deleteTime.trim();
    }

    public List<Menu> getChildren() {

        return children;
    }

    public void setChildren(List<Menu> children) {

        this.children = children;
    }

    public Boolean getOpen() {

        return open;
    }

    public void setOpen(Boolean open) {

        this.open = open;
    }

}